home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Deutsche Edition 1
/
Deutsche Edition 1.iso
/
amok
/
011-020
/
amok19
/
qtext
/
qtextdemo.mod
< prev
next >
Wrap
Text File
|
1993-11-04
|
2KB
|
69 lines
(*---------------------------------------------------------------------------
:Program. QTextDemo
:Contents. Demo for QText - a fast Text-Viewer
:Author. Fridtjof Siebert
:Address. Nobileweg 67, D-7-Stgt-40
:Phone. (0)711/822509
:Shortcut. [fbs]
:Version. 1.0
:Date. 29-Apr-89
:Copyright. PD
:Language. Modula-2
:Translator. M2Amiga v3.1d
:Remark. Sorry, but this compiles only under m2c V3.1d.
---------------------------------------------------------------------------*)
MODULE QTextDemo;
FROM SYSTEM IMPORT ADR;
FROM Dos IMPORT Delay;
FROM Graphics IMPORT TextAttr, FontStyleSet, FontFlagSet, OpenFont, CloseFont,
ViewModeSet, ViewModes, TextFontPtr;
FROM Intuition IMPORT NewScreen, ScreenPtr, customScreen, OpenScreen, CloseScreen,
ScreenFlags, ScreenFlagSet;
FROM QText IMPORT QText;
VAR
NuScreen: NewScreen;
Screen: ScreenPtr;
MyFont: TextAttr;
Font: TextFontPtr;
i,j,d,q,p: INTEGER;
Ciapra [0BFE001H]: SET OF (s0,s1,s2,s3,s4,s5,lmb);
BEGIN
WITH MyFont DO
name := ADR("topaz.font");
ySize := 8;
style := FontStyleSet{};
flags := FontFlagSet{};
END;
Font := OpenFont(ADR(MyFont));
WITH NuScreen DO
leftEdge := 0; topEdge := 0;
width := 640;
height := 2*256;
depth := 1;
detailPen := 0; blockPen := 1;
viewModes := ViewModeSet{hires};
font := NIL; defaultTitle := NIL;
gadgets := NIL; customBitMap := NIL;
type := customScreen + ScreenFlagSet{screenQuiet};
END;
Screen := OpenScreen(NuScreen);
j := 0; d := 1;
WHILE lmb IN Ciapra DO
INC(j,d);
IF (j=66) OR (j=0) THEN d := -d END;
p := j; q := d;
FOR i:=0 TO 248 BY 8 DO
QText(p,i,ADR(" Hello World! "),Screen^.rastPort.bitMap,Font);
INC(p,q);
IF (p=66) OR (p=0) THEN q := -q END;
END;
END;
CloseScreen(Screen);
CloseFont(Font);
END QTextDemo.